Rate = rate;
Randomizer = new Random();
Position = position;
+ CurrentTime = rate;
}
public void Update(GameTime gameTime)
{
- if (Game.Player.Score > ScoreThreshold)
+ if (ActorManager.CountBaddies() > 50)
+ {
+ return;
+ }
+
+ if (Game.Player.Score >= ScoreThreshold)
{
CurrentTime = CurrentTime + gameTime.ElapsedGameTime.Milliseconds;
if (ShipType == Ships.Ship)
{
- ActorFactory.CreateShip(polarity, Position);
+ Renderer.CheckIn(ActorFactory.CreateShip(polarity, Position));
}
if (ShipType == Ships.Scout)
{
- ActorFactory.CreateScout(polarity, Position);
+ Renderer.CheckIn(ActorFactory.CreateScout(polarity, Position));
}
if (ShipType == Ships.Battlecruiser)
{
- ActorFactory.CreateCruiser(polarity, Position);
+ Renderer.CheckIn(ActorFactory.CreateCruiser(polarity, Position));
}
}